import React from 'react';
import { Text, StyleSheet } from 'react-native';

interface IconProps {
  name: string;
  size?: number;
  color?: string;
  style?: any;
}

const iconMap: { [key: string]: string } = {
  'search': '🔍',
  'keyboard-arrow-down': '⌄',
  'settings': '⚙️',
  'check-circle': '✓',
  'psychology': '🧠',
  'cloud-upload': '☁️',
};

const Icon: React.FC<IconProps> = ({ name, size = 24, color = '#000', style }) => {
  const iconChar = iconMap[name] || '•';
  
  return (
    <Text style={[styles.icon, { fontSize: size, color }, style]}>
      {iconChar}
    </Text>
  );
};

const styles = StyleSheet.create({
  icon: {
    textAlign: 'center',
  },
});

export default Icon;
